package com.easyfile.easyfilemaster.entity.dto;

import com.easyfile.easyfilemaster.entity.base.ValidateRegex;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;


/**
 * 登录请求数据
 * @author chenpeman
 * @date 2022年05月06日 11:39
 */
@Data
public class LoginDto {
    @NotBlank(message = "手机号不能为空")
    @Pattern(regexp = ValidateRegex.MOBILE,message = "请输入正确的手机号")
    private String mobile;

    @NotBlank(message = "密码不能为空")
    @Pattern(regexp = ValidateRegex.PASSWORD,message = "用户名或密码错误")
    private String password;
}
